﻿@model IEnumerable<KRM.Core.vLoadDetail>
<script>
    $(document).ready(function () {
        var height = $(window).height() - 367;
        $(".loaddelivercontent table.krmtable").attr("data-height", height);
    })
</script>
<table class="table table-bordered table-fix krmtable tbl-selected">
    <thead>
        <tr>
            <th>LoadCode</th>
            <th>DriverName</th>
            <th>Vehicle</th>
            <th onclick="SortDate('planneddeliverydate')">PlannedDeliveryDate</th>
            <th onclick="SortDate('despatchdate')">DespatchDate</th>
            <th>LoadStatus</th>
        </tr>
    </thead>
    <tbody>
        @foreach (var item in Model)
        {
            <tr onclick="loaddeliverselected('@item.LoadID')">
                <td>@item.LoadCode</td>
                <td>@item.DriverName</td>
                <td>@item.Name</td>
                <td>@item.PlannedDeliveryDate</td>
                <td>@item.DespatchDate</td>
                <td>@item.LoadStatus</td>
            </tr>
        }
    </tbody>
</table>